Integrand size = 12, antiderivative size = 13 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=\log (1-\cos (x))-\log (\cos (x)) \]
[Out]
Time = 0.07 (sec) , antiderivative size = 13, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.417, Rules used = {4477, 2786, 36, 29, 31} \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=\log (1-\cos (x))-\log (\cos (x)) \]
[In]
[Out]
Rule 29
Rule 31
Rule 36
Rule 2786
Rule 4477
Rubi steps \begin{align*} \text {integral}& = \int \frac {\tan (x)}{1-\cos (x)} \, dx \\ & = -\text {Subst}\left (\int \frac {1}{x (1+x)} \, dx,x,-\cos (x)\right ) \\ & = -\text {Subst}\left (\int \frac {1}{x} \, dx,x,-\cos (x)\right )+\text {Subst}\left (\int \frac {1}{1+x} \, dx,x,-\cos (x)\right ) \\ & = \log (1-\cos (x))-\log (\cos (x)) \\ \end{align*}
Time = 0.02 (sec) , antiderivative size = 25, normalized size of antiderivative = 1.92 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=2 \log \left (\sin \left (\frac {x}{2}\right )\right )-\log \left (1-2 \sin ^2\left (\frac {x}{2}\right )\right ) \]
[In]
[Out]
Time = 0.37 (sec) , antiderivative size = 6, normalized size of antiderivative = 0.46
method | result | size |
derivativedivides | \(\ln \left (\sec \left (x \right )-1\right )\) | \(6\) |
default | \(\ln \left (\sec \left (x \right )-1\right )\) | \(6\) |
risch | \(2 \ln \left ({\mathrm e}^{i x}-1\right )-\ln \left ({\mathrm e}^{2 i x}+1\right )\) | \(22\) |
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 15, normalized size of antiderivative = 1.15 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=-\log \left (-\cos \left (x\right )\right ) + \log \left (-\frac {1}{2} \, \cos \left (x\right ) + \frac {1}{2}\right ) \]
[In]
[Out]
\[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=- \int \frac {\sec {\left (x \right )}}{\cot {\left (x \right )} - \csc {\left (x \right )}}\, dx \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 41 vs. \(2 (13) = 26\).
Time = 0.23 (sec) , antiderivative size = 41, normalized size of antiderivative = 3.15 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=-\log \left (\frac {\sin \left (x\right )}{\cos \left (x\right ) + 1} + 1\right ) - \log \left (\frac {\sin \left (x\right )}{\cos \left (x\right ) + 1} - 1\right ) + 2 \, \log \left (\frac {\sin \left (x\right )}{\cos \left (x\right ) + 1}\right ) \]
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 14, normalized size of antiderivative = 1.08 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=\log \left (-\cos \left (x\right ) + 1\right ) - \log \left ({\left | \cos \left (x\right ) \right |}\right ) \]
[In]
[Out]
Time = 22.65 (sec) , antiderivative size = 19, normalized size of antiderivative = 1.46 \[ \int \frac {\sec (x)}{-\cot (x)+\csc (x)} \, dx=2\,\ln \left (\mathrm {tan}\left (\frac {x}{2}\right )\right )-\ln \left ({\mathrm {tan}\left (\frac {x}{2}\right )}^2-1\right ) \]
[In]
[Out]